gtk4.git
8 years agogtkgesture: Drop GdkWindow checks
Carlos Garnacho [Fri, 31 Mar 2017 16:16:19 +0000 (18:16 +0200)]
gtkgesture: Drop GdkWindow checks

Those are now needless and wrong, as we get guarantees that handled
events will contain widget-relative coordinates. A side effect is
that these events are very possibly not explicitly sent to the
GdkWindow that implementations expect, any extra checks performed
through gtk_gesture_set_window() will be wrong, so the function has
been dropped entirely.

8 years agogtkexpander: Drop usage of gtk_gesture_set_window()
Carlos Garnacho [Fri, 31 Mar 2017 16:12:57 +0000 (18:12 +0200)]
gtkexpander: Drop usage of gtk_gesture_set_window()

It's now meaningless since the gesture will receive the event despite
the input only window.

8 years agogtkcolorplane: Drop usage of gtk_gesture_set_window()
Carlos Garnacho [Fri, 31 Mar 2017 16:11:52 +0000 (18:11 +0200)]
gtkcolorplane: Drop usage of gtk_gesture_set_window()

It's now meaningless since the widget will receive the event despite
the input window.

8 years agogtknotebook: Fix coordinate translation to happen on widget-relative coordinates
Carlos Garnacho [Fri, 31 Mar 2017 16:07:22 +0000 (18:07 +0200)]
gtknotebook: Fix coordinate translation to happen on widget-relative coordinates

This makes notebooks happy again after changing event coordinates to always come in
the widget coordinate system.

8 years agogtktextview: Drop GdkWindow checks on events
Carlos Garnacho [Fri, 31 Mar 2017 16:06:19 +0000 (18:06 +0200)]
gtktextview: Drop GdkWindow checks on events

These are now wrong and prevent the code from running correctly.

8 years agogtktreeview: Drop gtk_gesture_set_window() API
Carlos Garnacho [Fri, 31 Mar 2017 16:03:42 +0000 (18:03 +0200)]
gtktreeview: Drop gtk_gesture_set_window() API

It is now meaningless and wrong, since GdkWindows aren't used anymore
to determine the event target.

8 years agogtktextview: Set "text" pointer cursor
Carlos Garnacho [Fri, 31 Mar 2017 16:02:16 +0000 (18:02 +0200)]
gtktextview: Set "text" pointer cursor

This is no longer set through the Gdkwindow, so use private GtkWidget
API.

8 years agogtkentry: Remove text_area window
Carlos Garnacho [Fri, 31 Mar 2017 16:01:13 +0000 (18:01 +0200)]
gtkentry: Remove text_area window

And refurbish cursor management to be set on the GtkWidget. The
input window is not needed anymore to receive events either.

This is no longer set through the GdkWindow, so use the private
GtkWidget API.

8 years agogtkwidget: Add private cursor setter/getter
Carlos Garnacho [Fri, 31 Mar 2017 15:19:37 +0000 (17:19 +0200)]
gtkwidget: Add private cursor setter/getter

This should be eventually replaced by CSS cursors, but at the moment
it must be handled on the gtk/ side.

8 years agoimcontext: Remove API dependency on GdkWindow
Carlos Garnacho [Sat, 1 Apr 2017 21:25:13 +0000 (23:25 +0200)]
imcontext: Remove API dependency on GdkWindow

There is now a set_client_widget() to hint the IM about positioning
and whatnot.

8 years agogtkbutton: Handle crossing events without the event window
Carlos Garnacho [Fri, 31 Mar 2017 15:59:43 +0000 (17:59 +0200)]
gtkbutton: Handle crossing events without the event window

The event shall no longer be "directed" to the event window, but the
widget. Getting a enter/leave event is enough now to know whether the
pointer is inside or outside the widget.

8 years agogtkpointerfocus: Add methods to handle implicit grabs on widgets
Carlos Garnacho [Fri, 31 Mar 2017 15:57:44 +0000 (17:57 +0200)]
gtkpointerfocus: Add methods to handle implicit grabs on widgets

Just a basic setter/getter, plus a method to obtain the right logical target
in the presence or absence of these.

8 years agogtk: Implement per-focus implicit grabs
Carlos Garnacho [Fri, 31 Mar 2017 15:55:49 +0000 (17:55 +0200)]
gtk: Implement per-focus implicit grabs

Unlike GTK+ grabs which are global to all/one device, the implicit grab
is per focus, which means each may have implicit grabs on different or
the same widget.

8 years agogtk: Implement cursor updates
Carlos Garnacho [Fri, 31 Mar 2017 15:54:06 +0000 (17:54 +0200)]
gtk: Implement cursor updates

As we don't obey GdkWindow cursors anymore, someone must set those.
Use the private Gtkwidget API at the moment.

8 years agogtk: Update GtkPointerFocus targets on mapping/sensitivity changes
Carlos Garnacho [Fri, 31 Mar 2017 15:49:21 +0000 (17:49 +0200)]
gtk: Update GtkPointerFocus targets on mapping/sensitivity changes

Those are situations that must cause foci on these widgets to repick
themselves.

8 years agogdkwindow: Drop csw-side event translation
Carlos Garnacho [Fri, 31 Mar 2017 15:46:35 +0000 (17:46 +0200)]
gdkwindow: Drop csw-side event translation

Now that gtk_main_do_event() is able to handle pointing events in toplevel
coordinates, forward all of these as is. Just minimal handling is still done
on the gdk side for GDK grab accounting, and toplevel tracking for each
pointer.

8 years agogtk: Handle events with coordinates in toplevel-relative ones
Carlos Garnacho [Fri, 31 Mar 2017 15:38:38 +0000 (17:38 +0200)]
gtk: Handle events with coordinates in toplevel-relative ones

Implement target finding per-pointer/touchpoint through GtkPointerFocus and
_gtk_toplevel_pick(). Focus changes are handled through the emission of
crossing events between the old target and the new one.

8 years agogtkwindow: Add management functions for GtkPointerFocus instances
Carlos Garnacho [Fri, 31 Mar 2017 15:31:20 +0000 (17:31 +0200)]
gtkwindow: Add management functions for GtkPointerFocus instances

Each toplevel will keep its own tracking of the current ongoing foci,
add the plumbing that will allow to create/update/remove those as they
come and go.

8 years agogtk: Introduce GtkPointerFocus
Carlos Garnacho [Fri, 31 Mar 2017 15:22:00 +0000 (17:22 +0200)]
gtk: Introduce GtkPointerFocus

These objects (tied to a toplevel) track the focus of a pointer/touchpoint.
The info in these basically consists of current toplevel coordinates and the
current target widget.

8 years agogtkwidget: Expose gtk_widget_common_ancestor()
Carlos Garnacho [Fri, 31 Mar 2017 15:16:47 +0000 (17:16 +0200)]
gtkwidget: Expose gtk_widget_common_ancestor()

This function will be useful in other places, such as determining the
widgets that must receive crossing events after pointer picking points
to another widget.

8 years agogdk: Add gdk_event_set_coords() method
Carlos Garnacho [Fri, 31 Mar 2017 14:51:42 +0000 (16:51 +0200)]
gdk: Add gdk_event_set_coords() method

A helper function basically for gtk+, so coordinates can be translated
in place depending on the widget it's being delivered to.

8 years agogtk: Add private _gtk_toplevel_pick() method
Carlos Garnacho [Fri, 31 Mar 2017 14:49:22 +0000 (16:49 +0200)]
gtk: Add private _gtk_toplevel_pick() method

This function returns both the widget at the given toplevel coordinates,
and the translated x/y in widget relative coordinates.

8 years agoGtkWidget: Add ::pick vmethod
Carlos Garnacho [Fri, 12 May 2017 10:33:58 +0000 (12:33 +0200)]
GtkWidget: Add ::pick vmethod

The default implementation iterates through all children, so should suffice
for most widgets.

8 years agogdk: Add gdk_rectangle_contains_point() call
Carlos Garnacho [Fri, 12 May 2017 09:46:33 +0000 (11:46 +0200)]
gdk: Add gdk_rectangle_contains_point() call

A little helper function for a somewhat common operation.

8 years agowayland: Don't abort when preparing the source if connection is lost
Debarshi Ray [Wed, 24 May 2017 14:08:07 +0000 (16:08 +0200)]
wayland: Don't abort when preparing the source if connection is lost

Aborting the application makes it look like an application bug, when
it is the expected thing to do when the Wayland display server goes
way. eg., when the user logs out. The log level is also demoted to
avoid a storm of warnings in the log from all applications whenever
this happens.

This is also what the X11 backend does (see gdk_x_io_error).

https://bugzilla.gnome.org/show_bug.cgi?id=783047

8 years ago3.91.0
Matthias Clasen [Mon, 22 May 2017 20:39:09 +0000 (16:39 -0400)]
3.91.0

8 years agoUpdate a11y test output
Matthias Clasen [Tue, 23 May 2017 01:42:01 +0000 (21:42 -0400)]
Update a11y test output

8 years agoFix the docs build
Matthias Clasen [Mon, 22 May 2017 21:35:23 +0000 (17:35 -0400)]
Fix the docs build

gtk-doc behavior changed, it seems, and these options now
cause the build to break.

8 years agodocs: Fix copy-paste error in gtk_file_chooser_get_extra_widget() doc comment
Robert Ancell [Sat, 20 May 2017 01:07:05 +0000 (13:07 +1200)]
docs: Fix copy-paste error in gtk_file_chooser_get_extra_widget() doc comment

8 years agoAdwaita: Avoid accindental border on last treeview header
Lapo Calamandrei [Wed, 17 May 2017 16:09:59 +0000 (18:09 +0200)]
Adwaita: Avoid accindental border on last treeview header

The :last-child selector supposed to reset the border was
overridden by the :hover selector. This is fixed by moving the
:last-child selector after the overriding one.
Thanks to Sebastian Keller for spotting.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=779078.

8 years agoEntryBuffer: Don't generate changed events when input is truncated
Robert Ancell [Mon, 15 May 2017 05:03:36 +0000 (17:03 +1200)]
EntryBuffer: Don't generate changed events when input is truncated

8 years agomeson: remove duplicated G_ENABLE_DEBUG
Ignacio Casal Quinteiro [Tue, 16 May 2017 20:50:00 +0000 (22:50 +0200)]
meson: remove duplicated G_ENABLE_DEBUG

8 years agoFrame: Don’t advise adding .flat class in code
Daniel Boles [Sun, 14 May 2017 10:46:34 +0000 (11:46 +0100)]
Frame: Don’t advise adding .flat class in code

https://bugzilla.gnome.org/show_bug.cgi?id=779653#c33
and this is closer to what gtk-3-22 says anyway.

8 years agowidget-factory: Use :relief=none, not class .flat
Daniel Boles [Sat, 13 May 2017 18:28:34 +0000 (19:28 +0100)]
widget-factory: Use :relief=none, not class .flat

The rest of the ui file follows that convention.

8 years agogtk-demo: ui: Replace leftover uses of Box:expand
Daniel Boles [Sat, 13 May 2017 17:08:51 +0000 (18:08 +0100)]
gtk-demo: ui: Replace leftover uses of Box:expand

commit 5729ea7744c2a41ae8fb833db6690a6aa5ad7a84 skipped these

8 years agodemo/toolpalette: Restore ToolItemGroup child prop
Daniel Boles [Sat, 13 May 2017 17:04:19 +0000 (18:04 +0100)]
demo/toolpalette: Restore ToolItemGroup child prop

…erties clobbered by commit c92b7d4224b9cef1d08373fcc28f7fbd96c64e6d.
That and its counterpart were for removing :expand and :fill child props
from GtkBox, but they ended up catching these for GtkToolItemGroup too.

While GtkToolItemGroup still has these, we may as well keep demoing them

8 years agoAdwaita: regenerate the css
Lapo Calamandrei [Thu, 11 May 2017 13:26:48 +0000 (15:26 +0200)]
Adwaita: regenerate the css

8 years agoAdwaita: restyle entry-tag
Lapo Calamandrei [Thu, 11 May 2017 12:36:57 +0000 (14:36 +0200)]
Adwaita: restyle entry-tag

Fix the sizing and spacing, blue tags for the bright variant,
similar to what gnome-documents was shipping, and inverted gray
tags for the dark variant, not vanishing on hover.

8 years agotestsuite/scrolledwindow: Try non-overlay/non-auto
Daniel Boles [Fri, 24 Feb 2017 22:46:05 +0000 (22:46 +0000)]
testsuite/scrolledwindow: Try non-overlay/non-auto

It was only testing the default configuration, where overlay scrolling
is on and both scrollbars use POLICY_AUTOMATIC. We should also test the
other 3 configurations that are available by including non-overlay
scrollbars and/or those that use POLICY_ALWAYS.

https://bugzilla.gnome.org/show_bug.cgi?id=778853

8 years agoScrolledWindow: Don’t req size for autohidden bars
Daniel Boles [Fri, 24 Feb 2017 22:46:05 +0000 (22:46 +0000)]
ScrolledWindow: Don’t req size for autohidden bars

POLICY_AUTOMATIC means scrollbars are only shown when needed, i.e. when
the size of the window is not large enough to show the entire child. So
when measuring the preferred size, such scrollbars should be ignored.

But measure() added size for *any* non-overlay scrollbar of the opposite
orientation, e.g. for horizontal size, it added the width of vscrollbar.
So we requested for child + bar, & having enough for child meant that the
policy hid the bar, leaving extra space empty below/right of the child.

Fix this by only adding size for such bars if they use POLICY_ALWAYS.

https://bugzilla.gnome.org/show_bug.cgi?id=778853

8 years agoScrolledWindow: Optimise and clean up measure()
Daniel Boles [Fri, 10 Mar 2017 20:09:20 +0000 (20:09 +0000)]
ScrolledWindow: Optimise and clean up measure()

 • Only calculate the specified dimension – rather than measuring both &
   discarding the other (which will often be recalculated right after)
 • Only measure a given child scrollbar if it may be visible, not always
 • Move variables into narrowest scopes & otherwise improve readability

https://bugzilla.gnome.org/show_bug.cgi?id=778853

8 years agogtkclipboard: Fix typo
Carlos Garnacho [Wed, 10 May 2017 18:20:50 +0000 (20:20 +0200)]
gtkclipboard: Fix typo

The standard atom is UTF8_STRING.

8 years agotestsuite/gtk/scrolledwindow: Fix a copy-paste-o
Daniel Boles [Wed, 10 May 2017 18:11:16 +0000 (19:11 +0100)]
testsuite/gtk/scrolledwindow: Fix a copy-paste-o

It measured horizontal size when it needs height, making the test fail.

8 years agomeson: Use buildtype to determine the debugging flags
Emmanuele Bassi [Wed, 10 May 2017 11:03:01 +0000 (12:03 +0100)]
meson: Use buildtype to determine the debugging flags

Meson has a `--buildtype` option which allows us to avoid defining an ad
hoc `--enable-debug=yes|no|minimum` option ourselves.

8 years agomeson: Drop unnecessary link_with
Emmanuele Bassi [Wed, 10 May 2017 10:36:30 +0000 (11:36 +0100)]
meson: Drop unnecessary link_with

The `declare_dependency()` for GIR does not need a `link_with` argument.

8 years agomeson: Build the reftests suite
Emmanuele Bassi [Sat, 6 May 2017 16:25:42 +0000 (17:25 +0100)]
meson: Build the reftests suite

It does not pass, but at least we can check it.

8 years agomeson: Use libexecdir option
Emmanuele Bassi [Sat, 6 May 2017 16:25:13 +0000 (17:25 +0100)]
meson: Use libexecdir option

8 years agowin32/replace.py: Fix replacing items in files with UTF-8 content
Chun-wei Fan [Wed, 10 May 2017 01:17:29 +0000 (18:17 -0700)]
win32/replace.py: Fix replacing items in files with UTF-8 content

Some files that this script will process might have UTF-8 items in
there, which can cause problems on Python 3.x as it is more strict and
careful on unicode issues.  Fix this by:

-Doing what we did before on Python 2.x
-Opening the file with encoding='utf-8' on Python 3.x

8 years agoGtkWindow: Don't double free export user data
Jonas Ådahl [Tue, 9 May 2017 15:07:02 +0000 (23:07 +0800)]
GtkWindow: Don't double free export user data

The user data passed when exporting a Wayland window was supposed to be
freed using the destroy_func, as is commonly done. This was previously
broken, as the user data was just NULL:ed when exported, and only
actually destroyed when unexporting before having exported.

While e016d9a5dba6f6f99aee94d0b72c00bee299b96a fixed this, it introduced
a regression, as GtkWindow was nice enough to free the memory anyway
after having received the exported handle, causing it now to double
free.

https://bugzilla.gnome.org/show_bug.cgi?id=782109

8 years agoAdwaita: regenerate the css
Lapo Calamandrei [Tue, 9 May 2017 11:39:05 +0000 (13:39 +0200)]
Adwaita: regenerate the css

8 years agoAdwaita: add a comment
Lapo Calamandrei [Tue, 9 May 2017 11:38:03 +0000 (13:38 +0200)]
Adwaita: add a comment

Add a comment pointing to the related bug for dropdown menu
margin.

8 years agoRevert "Adwaita: remove unneeded margin on dropdown menu"
Lapo Calamandrei [Tue, 9 May 2017 11:34:49 +0000 (13:34 +0200)]
Revert "Adwaita: remove unneeded margin on dropdown menu"

This reverts commit af76e138f947d5cf3e83e4b820f7e64fd0316799.
The margin was actually related to:
https://bugzilla.gnome.org/show_bug.cgi?id=591258

8 years agoAdwaita: regenerate css
Lapo Calamandrei [Tue, 9 May 2017 10:47:41 +0000 (12:47 +0200)]
Adwaita: regenerate css

8 years agoAdwaita: remove unneeded margin on dropdown menu
Lapo Calamandrei [Tue, 9 May 2017 10:45:22 +0000 (12:45 +0200)]
Adwaita: remove unneeded margin on dropdown menu

That margin was probably a left over to workaround some placement
issue on dropdowns which doesn't exist anymore.

8 years agoGdkWaylandWindow: Unexport when finalizing
Jonas Ådahl [Mon, 8 May 2017 04:09:00 +0000 (12:09 +0800)]
GdkWaylandWindow: Unexport when finalizing

The application might not have exported, and it'll be too late for it
at this point anyway, so lets be helpful and not leak it.

https://bugzilla.gnome.org/show_bug.cgi?id=782109

8 years agoMake sure to remove tooltip timeout.
Olof-Joachim Frahm [Sun, 5 Feb 2017 18:08:56 +0000 (19:08 +0100)]
Make sure to remove tooltip timeout.

Otherwise in GC-ed environments the `g_source_remove` call during
disposal might be called on an already removed source, which results in
unnecessary console output.

https://bugzilla.gnome.org/show_bug.cgi?id=778301

8 years agostyle entry-tags
Jakub Steiner [Thu, 13 Apr 2017 17:38:53 +0000 (19:38 +0200)]
style entry-tags

https://bugzilla.gnome.org/show_bug.cgi?id=781214

8 years agowayland: Remove self assignment
Jonas Ådahl [Mon, 20 Mar 2017 13:37:10 +0000 (21:37 +0800)]
wayland: Remove self assignment

Don't assign the value of a variable to itself. It was added just for
clarity, but it makes coverity complain, so remove it.

https://bugzilla.gnome.org/show_bug.cgi?id=780301

8 years agowayland: Use correct enum type and values
Jonas Ådahl [Mon, 20 Mar 2017 13:36:29 +0000 (21:36 +0800)]
wayland: Use correct enum type and values

Use the gravity enum values when converting to gravity. It doesn't fix
anything, since the enum values were identical, but it makes a coverity
warning go away.

https://bugzilla.gnome.org/show_bug.cgi?id=780301

8 years agofile filter: Be save against NULL
Matthias Clasen [Mon, 8 May 2017 20:35:53 +0000 (16:35 -0400)]
file filter: Be save against NULL

g_content_type_from_mime_type may return NULL, deal with that.

https://bugzilla.gnome.org/show_bug.cgi?id=782180

8 years agoRevert "GdkWaylandWindow: Unexport when finalizing"
Matthias Clasen [Mon, 8 May 2017 19:59:23 +0000 (15:59 -0400)]
Revert "GdkWaylandWindow: Unexport when finalizing"

This reverts commit 251e216052cab4fd04e39c7872395b64363c11da.

8 years agoGdkWaylandWindow: Unexport when finalizing
Jonas Ådahl [Mon, 8 May 2017 04:09:00 +0000 (12:09 +0800)]
GdkWaylandWindow: Unexport when finalizing

The application might not have exported, and it'll be too late for it
at this point anyway, so lets be helpful and not leak it.

https://bugzilla.gnome.org/show_bug.cgi?id=782109

8 years agoGdkWaylandWindow: Clear export user data when used
Jonas Ådahl [Fri, 5 May 2017 11:07:04 +0000 (19:07 +0800)]
GdkWaylandWindow: Clear export user data when used

It was only cleared when unexported, but we could just as well clear it
when its used too.

https://bugzilla.gnome.org/show_bug.cgi?id=782109

8 years agomenubutton: Remove prelight state when button is deactivated
Michael Catanzaro [Sun, 30 Apr 2017 18:26:13 +0000 (13:26 -0500)]
menubutton: Remove prelight state when button is deactivated

If the button is deactivated, it should not appear to be hovered
anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=781992

8 years agoUpdate Hungarian translation
Balázs Úr [Fri, 5 May 2017 18:56:59 +0000 (18:56 +0000)]
Update Hungarian translation

8 years agogtkdnd: restore drag window movement for the unmanaged case
Christoph Reiter [Wed, 26 Apr 2017 10:46:40 +0000 (12:46 +0200)]
gtkdnd: restore drag window movement for the unmanaged case

5bb12474d975ee4b790c5 removed the dnd window movement code to let
the gdk backends handle the window movement instead. While this
works for X11/wayland the win32 backend still uses the unmanaged
interface and expects the window movement to be handled on the gtk
side. This restores the functionality in case the dnd is unmanaged.

This fixes the drag window on Windows being stuck in the top left
corner instead of following the drag position.

https://bugzilla.gnome.org/show_bug.cgi?id=781737

8 years agoUpdated Slovenian translation
Matej Urbančič [Fri, 5 May 2017 11:25:51 +0000 (13:25 +0200)]
Updated Slovenian translation

8 years agomeson: Generate man pages for the installed tools
Emmanuele Bassi [Fri, 5 May 2017 10:34:05 +0000 (11:34 +0100)]
meson: Generate man pages for the installed tools

8 years agomeson: Silence the introspection scanner
Emmanuele Bassi [Fri, 5 May 2017 10:16:06 +0000 (11:16 +0100)]
meson: Silence the introspection scanner

We want the warnings, but not every single message.

8 years agoMove style change for popover creation.
Olof-Joachim Frahm [Sun, 26 Feb 2017 15:02:49 +0000 (16:02 +0100)]
Move style change for popover creation.

Creating with `gtk_popover_new_from_model` should be exactly the same as
if via `gtk_popover_new` plus `gtk_popover_bind_model`.

Also remove the style if the model is unbound at any point.

8 years agolinkbutton: Fix memory leak
Mohammed Sadiq [Fri, 5 May 2017 05:22:27 +0000 (10:52 +0530)]
linkbutton: Fix memory leak

strings returned by gtk_widget_get_tooltip_text() and
gtk_widget_get_tooltip_markup() has to be freed when no longer
required.

https://bugzilla.gnome.org/show_bug.cgi?id=782202

8 years agoRemove gtk_widget_get_preferred_*
Timm Bäder [Tue, 2 May 2017 19:50:50 +0000 (21:50 +0200)]
Remove gtk_widget_get_preferred_*

They are unnecessary now that we have gtk_widget_measure.

8 years agowindow: Stop using gtk_widget_get_preferred*
Timm Bäder [Wed, 3 May 2017 14:37:55 +0000 (16:37 +0200)]
window: Stop using gtk_widget_get_preferred*

8 years agowidget: Remove useless assignment
Timm Bäder [Tue, 2 May 2017 18:54:57 +0000 (20:54 +0200)]
widget: Remove useless assignment

We don't use adjusted_allocation after this line.

8 years agobutton: Remove baseline_align value
Timm Bäder [Tue, 2 May 2017 17:11:53 +0000 (19:11 +0200)]
button: Remove baseline_align value

It's unused.

8 years agoclipboard: Try the mimetype first
Matthias Clasen [Wed, 3 May 2017 21:08:29 +0000 (17:08 -0400)]
clipboard: Try the mimetype first

Try text/plain;charset=utf-8 first, before falling back to
X11-isms like UTF8_TEXT. This makes things work on Wayland
compositors that don't carry a heavy X11 legacy around.

https://bugzilla.gnome.org/show_bug.cgi?id=781814

8 years agomeson: simplify cups version check in printbackends
Tim-Philipp Müller [Wed, 3 May 2017 17:40:56 +0000 (18:40 +0100)]
meson: simplify cups version check in printbackends

Using cc.compute_int() instead of cc.get_define() for now
as there seems to be some issue with get_define() (#1726).

8 years agoAdwaita: regenerate css using sassc
Lapo Calamandrei [Wed, 3 May 2017 15:43:45 +0000 (17:43 +0200)]
Adwaita: regenerate css using sassc

8 years agoAdwaita: add more space between check/radio and label in popovers
Lapo Calamandrei [Wed, 3 May 2017 15:39:21 +0000 (17:39 +0200)]
Adwaita: add more space between check/radio and label in popovers

See https://bugzilla.gnome.org/show_bug.cgi?id=779570 for details.

8 years agoAdwaita: add a sassc based parse-sass.sh script
Lapo Calamandrei [Wed, 3 May 2017 15:31:50 +0000 (17:31 +0200)]
Adwaita: add a sassc based parse-sass.sh script

8 years agomeson: Remove G_LOG_USE_STRUCTURED from target C flags
Emmanuele Bassi [Wed, 3 May 2017 15:22:52 +0000 (16:22 +0100)]
meson: Remove G_LOG_USE_STRUCTURED from target C flags

The G_LOG_USE_STRUCTURED symbol is defined in the project flags, so we
don't need to add it again in the per-target flags.

8 years agomeson: depend on glib >= 2.53.1
Ernestas Kulik [Wed, 3 May 2017 14:36:45 +0000 (17:36 +0300)]
meson: depend on glib >= 2.53.1

The code uses g_object_new_with_properties(), which is only available in
versions 2.53.1 and up.

https://bugzilla.gnome.org/show_bug.cgi?id=782123

8 years agobuild: Use appropriate linker flag for the builder test
Emmanuele Bassi [Wed, 3 May 2017 15:11:17 +0000 (16:11 +0100)]
build: Use appropriate linker flag for the builder test

The `-export-dynamic` flag is a libtool-specific flag; since we're not
using libtool with Meson, we should instruct the C compiler to use the
appropriate linker flag instead.

8 years agowindow: Remove property definition
Emmanuele Bassi [Wed, 3 May 2017 14:58:49 +0000 (15:58 +0100)]
window: Remove property definition

Commit 92b0d2e8ea8b41ea914eb4d66b48cc7dd2d34b9d removed the
hide-titlebar-when-maximized property handlers, but it still installed
the GParamSpec into the GtkWindow class.

8 years agoSpecify more options to sassc
Emmanuele Bassi [Wed, 3 May 2017 14:46:35 +0000 (15:46 +0100)]
Specify more options to sassc

We should use the compact style, to minimize the whitespace; and we
should omit the source map URL comment as well.

8 years agobuild: De-duplicate options to sassc
Emmanuele Bassi [Wed, 3 May 2017 14:45:15 +0000 (15:45 +0100)]
build: De-duplicate options to sassc

If we want to change the list of options we use with sassc, not having
to copy-paste them in multiple rules would be a good start.

8 years agotestsuite: Remove unused function
Emmanuele Bassi [Wed, 3 May 2017 14:21:20 +0000 (15:21 +0100)]
testsuite: Remove unused function

Silence a compiler warning.

8 years agobuild: Port the a11y test suite to Meson
Emmanuele Bassi [Sun, 30 Apr 2017 21:14:37 +0000 (22:14 +0100)]
build: Port the a11y test suite to Meson

Copy the location of the test data and binaries from the autotools
build, even though it's not really correct; currently we install the
test data under libexecdir, but it should live under datadir, and we
should use `G_TEST_DIST` to figure it out.

The `state` subdirectory is missing.

8 years agobuild: Add common settings for tests
Emmanuele Bassi [Sun, 30 Apr 2017 21:13:47 +0000 (22:13 +0100)]
build: Add common settings for tests

We are going to reuse them in the various parts of the test suite.

8 years agobuild: Update autotools for API reference changes
Emmanuele Bassi [Sun, 30 Apr 2017 11:39:59 +0000 (12:39 +0100)]
build: Update autotools for API reference changes

8 years agobuild: Add Meson-related files to the autotools dist
Emmanuele Bassi [Fri, 28 Apr 2017 22:48:43 +0000 (23:48 +0100)]
build: Add Meson-related files to the autotools dist

This way, a tarball generated via autotools will also allow building
GTK+ via Meson.

8 years agobuild: Use link_whole for GDK backends
Emmanuele Bassi [Fri, 28 Apr 2017 21:41:50 +0000 (22:41 +0100)]
build: Use link_whole for GDK backends

When linking libgdk4 to each backend's static library, we want to use
the whole-archive support.

8 years agobuild: Define G_LOG_USE_STRUCTURED in GDK
Emmanuele Bassi [Fri, 28 Apr 2017 21:40:58 +0000 (22:40 +0100)]
build: Define G_LOG_USE_STRUCTURED in GDK

We want to use the new structured logging support in GLib.

8 years agobuild: Add common flags to GDK backends
Emmanuele Bassi [Fri, 28 Apr 2017 21:26:32 +0000 (22:26 +0100)]
build: Add common flags to GDK backends

The common compiler and linker flags control, among other things, the
default visibility of symbols; without them, we leak symbols that ought
to be private.

8 years agobuild: Fix the introspection build
Emmanuele Bassi [Fri, 28 Apr 2017 14:23:45 +0000 (15:23 +0100)]
build: Fix the introspection build

GSK has various enumeration types that are currently not used; while
they may go away, currently they are built and introspected. If we want
the introspection machinery to work, and still use static libraries to
build GDK and GSK into the GTK shared library, then we need to reference
the get_type() function of these enumeration types somewhere, to avoid
the linker discarding it, and thus breaking the build.

As luck would have it, we have an autogenerated bit of C that refers to
all the get_type() functions in the library; if we add the GSK types to
it, then we get the reference we're looking for, and the build succeeds.

8 years agobuild: Depend on Meson 0.40 at least
Emmanuele Bassi [Fri, 28 Apr 2017 14:49:00 +0000 (15:49 +0100)]
build: Depend on Meson 0.40 at least

8 years agobuild: Initial attempt at fixing the docs build
Emmanuele Bassi [Wed, 26 Apr 2017 16:47:06 +0000 (17:47 +0100)]
build: Initial attempt at fixing the docs build

We need to reference the types file directly, because it won't be copied
into the builddir by Meson — except for GTK, which needs to generate its
own types file using configure_file().

8 years agobuild: Use get_pkgconfig_variable()
Emmanuele Bassi [Wed, 26 Apr 2017 16:10:15 +0000 (17:10 +0100)]
build: Use get_pkgconfig_variable()

There's no need to run pkg-config ourselves.

8 years agobuild: Improve consistency of the "coding" style
Emmanuele Bassi [Wed, 26 Apr 2017 16:04:20 +0000 (17:04 +0100)]
build: Improve consistency of the "coding" style

We're mixing a lot of styles in the Meson build files. This is an
attempt at making everything slightly more consistent in terms of
whitespace and indentation.

8 years agobuild: Clean up print backends Meson rules
Emmanuele Bassi [Wed, 26 Apr 2017 16:02:26 +0000 (17:02 +0100)]
build: Clean up print backends Meson rules